/*
* $Id: WizardStep.h 340 2011-10-20 08:08:01Z volok-aleksej@yandex.ru $
*
* Copyright 2009-2011 by Volokitin Aleksey
* All rights reserved
*
*/
#ifndef _WIZARD_STEP_H_
#define _WIZARD_STEP_H_

#include "MessageHandler.h"

class CWizardStep
{
protected:
	std::vector<CWnd*> m_aWindows;
	CWizardStep* m_pBack;
	CWnd* m_pParentWnd;
public:
	CWizardStep(CWizardStep* pBack, CWnd* pParent);
	virtual ~CWizardStep();
public:
	void AddWindow(CWnd* pWindow);
	void RemoveWindow(CWnd* pWindow);
public:
	virtual void Init(CPoint offset) = 0;
	virtual CWizardStep* Next() = 0;
	virtual CWizardStep* Back() = 0;
	virtual void Update() = 0;
	DECLARE_MESSAGE_HANDLER();
protected:
	void CloseWindows();
};

class CWizardWarningStep : public CWizardStep
{
protected:
	CStatic* m_pWarning;
public:
	CWizardWarningStep(CWizardStep* pBack, CWnd* pParent);
	virtual ~CWizardWarningStep();
public:
	virtual void Init(CPoint offset);
	virtual void Update();
protected:
	virtual void InitMain(CPoint offset) = 0;
	virtual void InitWarning(CPoint offset) = 0;
private:
	bool IsMainAppStarted();
};

#endif/*_WIZARD_STEP_H_*/